QuickTime 4 API Documentation

3D Graphics Programming with QuickDraw 3D 1.5.4

Previous | QD3D Book | Overview | Chapter Contents | Next |

Creating and Editing Meshes

QuickDraw 3D provides routines that you can use to create and manipulate meshes. See "Meshes" for the definition of a mesh and its associated types.

Q3Mesh_New

You can use the Q3Mesh_New function to create a new mesh.

TQ3GeometryObject Q3Mesh_New (void);

DESCRIPTION

The Q3Mesh_New function returns, as its function result, a new mesh. The new mesh is empty; you need to call other QuickDraw 3D routines to add vertices and faces to the mesh. If a new mesh could not be created, Q3Mesh_New returns the value NULL .

Q3Mesh_VertexNew

You can use the Q3Mesh_VertexNew function to add a vertex to a mesh.

TQ3MeshVertex Q3Mesh_VertexNew (
                     TQ3GeometryObject mesh,
                     const TQ3Vertex3D *vertex);
mesh
A mesh.
vertex
A three-dimensional vertex.

DESCRIPTION

The Q3Mesh_VertexNew function adds the vertex specified by the vertex parameter to the mesh specified by the mesh parameter. The mesh must already exist before you call Q3Mesh_VertexNew . The new mesh vertex is returned as the function result, of type TQ3MeshVertex.

Q3Mesh_VertexDelete

You can use the Q3Mesh_VertexDelete function to delete a vertex from a mesh.

TQ3Status Q3Mesh_VertexDelete (
                     TQ3GeometryObject mesh,
                     TQ3MeshVertex vertex);
mesh
A mesh.
vertex
A mesh vertex.

DESCRIPTION

The Q3Mesh_VertexDelete function deletes the mesh vertex specified by the vertex parameter from the mesh specified by the mesh parameter. All mesh faces that contain the vertex are also deleted.

Q3Mesh_FaceNew

You can use the Q3Mesh_FaceNew function to add a face to a mesh.

TQ3MeshFace Q3Mesh_FaceNew (
                     TQ3GeometryObject mesh,
                     unsigned long numVertices,
                     const TQ3MeshVertex *vertices,
                     TQ3AttributeSet attributeSet);
mesh
A mesh.
numVertices
The number of mesh vertices in the vertices array.
vertices
A pointer to an array of mesh vertices defining the new mesh face. These vertices can be ordered either clockwise or counterclockwise.
attributeSet
The desired set of attributes for the new mesh face. Set this parameter to NULL if you do no want any attributes for the new face.

DESCRIPTION

The Q3Mesh_FaceNew function adds the face specified by the vertices parameter to the mesh specified by the mesh parameter. The mesh must already exist before you call Q3Mesh_FaceNew . The new mesh face is returned as the function result.

Q3Mesh_FaceDelete

You can use the Q3Mesh_FaceDelete function to delete a face from a mesh.

TQ3Status Q3Mesh_FaceDelete (
                     TQ3GeometryObject mesh,
                     TQ3MeshFace face);
mesh
A mesh.
face
A mesh face.

DESCRIPTION

The Q3Mesh_FaceDelete function deletes the mesh face specified by the face parameter from the mesh specified by the mesh parameter. The vertices of the face are not deleted.

Q3Mesh_DelayUpdates

You can use the Q3Mesh_DelayUpdates function to prevent QuickDraw 3D from updating its internal list of mesh components.

TQ3Status Q3Mesh_DelayUpdates (TQ3GeometryObject mesh);
mesh
A mesh.

DESCRIPTION

The Q3Mesh_DelayUpdates function prevents QuickDraw 3D from updating its internal list of components and maintaining correct face orientation (that is, vertex ordering) for the mesh specified by the mesh parameter. Updating the list of components can consume significant amounts of time, and it might be useful temporarily to prevent component list updating. You should later call Q3Mesh_ResumeUpdates to resume component list updating. Generally, if you are creating or deleting a number of vertices or faces from a mesh, it is better to bracket the entire set of changes with calls to Q3Mesh_DelayUpdates and Q3Mesh_ResumeUpdates .

Q3Mesh_ResumeUpdates

You can use the Q3Mesh_ResumeUpdates function to have QuickDraw 3D resume updating its internal list of mesh components.

TQ3Status Q3Mesh_ResumeUpdates (TQ3GeometryObject mesh);
mesh
A mesh.

DESCRIPTION

The Q3Mesh_ResumeUpdates function instructs QuickDraw 3D to resume updating its internal list of components and maintaining correct face orientation for the mesh specified by the mesh parameter.

Q3Mesh_FaceToContour

You can use the Q3Mesh_FaceToContour function to convert a face of a mesh into a contour. The contour is then attached to another mesh face as a hole.

TQ3MeshContour Q3Mesh_FaceToContour (
                     TQ3GeometryObject mesh,
                     TQ3MeshFace containerFace,
                     TQ3MeshFace face);
mesh
A mesh.
containerFace
The mesh face that is to contain the new contour.
face
The mesh face that is to be converted into a contour. On exit, this face is no longer a valid object.

DESCRIPTION

The Q3Mesh_FaceToContour function returns, as its function result, a new contour created from the mesh face specified by the mesh and face parameters. The new contour is contained in the mesh face specified by the mesh and containerFace parameters. If a new contour could not be created, Q3Mesh_FaceToContour returns the value NULL .

Q3Mesh_FaceToContour destroys any attributes associated with the face specified by the face parameter.

Q3Mesh_ContourToFace

You can use the Q3Mesh_ContourToFace function to convert a mesh contour into a mesh face.

TQ3MeshFace Q3Mesh_ContourToFace (
                     TQ3GeometryObject mesh,
                     TQ3MeshContour contour);
mesh
A mesh.
contour
A mesh contour. On exit, this contour is no longer a valid object.

DESCRIPTION

The Q3Mesh_ContourToFace function returns, as its function result, a mesh face that is the result of removing the mesh contour specified by the mesh and contour parameters from its containing face. (You can call the Q3Mesh_GetContourFace function to determine the face that contains a mesh contour; see [link] .) If a new face could not be created, Q3Mesh_ContourToFace returns the value NULL .

Q3Mesh_GetNumComponents

You can use the Q3Mesh_GetNumComponents function to determine the number of connected components of a mesh.

TQ3Status Q3Mesh_GetNumComponents (
                     TQ3GeometryObject mesh,
                     unsigned long *numComponents);
mesh
A mesh.
numComponents
On exit, the number of connected components in the specified mesh.

DESCRIPTION

The Q3Mesh_GetNumComponents function returns, in the numComponents parameter, the number of connected components in the mesh specified by the mesh parameter. A connected component is a list of vertices, each of which is connected to all the others by some sequence of mesh edges. For example, a mesh that contains two cubes has two components.

SPECIAL CONSIDERATIONS

The Q3Mesh_GetNumComponents function might not accurately report the number of connected components in a mesh if called while mesh updating is delayed (that is, after a call to Q3Mesh_DelayUpdates but before the matching call to Q3Mesh_ResumeUpdates ).

Q3Mesh_GetNumEdges

You can use the Q3Mesh_GetNumEdges function to determine the number of edges of a mesh.

TQ3Status Q3Mesh_GetNumEdges (
                     TQ3GeometryObject mesh,
                     unsigned long *numEdges);
mesh
A mesh.
numEdges
On exit, the number of edges in the specified mesh.

DESCRIPTION

The Q3Mesh_GetNumEdges function returns, in the numEdges parameter, the number of edges in the mesh specified by the mesh parameter.

Q3Mesh_GetNumVertices

You can use the Q3Mesh_GetNumVertices function to determine the number of vertices of a mesh.

TQ3Status Q3Mesh_GetNumVertices (
                     TQ3GeometryObject mesh,
                     unsigned long *numVertices);
mesh
A mesh.
numVertices
On exit, the number of vertices in the specified mesh.

DESCRIPTION

The Q3Mesh_GetNumVertices function returns, in the numVertices parameter, the number of vertices in the mesh specified by the mesh parameter.

Q3Mesh_GetNumFaces

You can use the Q3Mesh_GetNumFaces function to determine the number of faces of a mesh.

TQ3Status Q3Mesh_GetNumFaces (
                     TQ3GeometryObject mesh,
                     unsigned long *numFaces);
mesh
A mesh.
numFaces
On exit, the number of faces in the specified mesh.

DESCRIPTION

The Q3Mesh_GetNumFaces function returns, in the numFaces parameter, the number of faces in the mesh specified by the mesh parameter.

Q3Mesh_GetNumCorners

You can use the Q3Mesh_GetNumCorners function to determine the number of corners of a mesh that have attribute sets.

TQ3Status Q3Mesh_GetNumCorners (
                     TQ3GeometryObject mesh,
                     unsigned long *numCorners);
mesh
A mesh.
numCorners
On exit, the number of corners in the specified mesh that have attribute sets.

DESCRIPTION

The Q3Mesh_GetNumCorners function returns, in the numCorners parameter, the number of corners in the mesh specified by the mesh parameter that have attribute sets attached to them.

Q3Mesh_GetOrientable

You can use the Q3Mesh_GetOrientable function to determine whether the faces of a mesh can be consistently oriented.

TQ3Status Q3Mesh_GetOrientable (
                     TQ3GeometryObject mesh,
                     TQ3Boolean *orientable);
mesh
A mesh.
orientable
On exit, a Boolean value that indicates whether the faces of the specified mesh can be consistently oriented.

DESCRIPTION

The Q3Mesh_GetOrientable function returns, in the orientable parameter, the value kQ3True if the faces of the mesh specified by the mesh parameter can be consistently oriented; Q3Mesh_GetOrientable returns kQ3False otherwise. For example, the faces of a tessellated Möbius strip or a Klein bottle cannot be consistently oriented.

SPECIAL CONSIDERATIONS

The Q3Mesh_GetOrientable function might not accurately report the orientation state of a mesh if called while mesh updating is delayed (that is, after a call to Q3Mesh_DelayUpdates but before the matching call to Q3Mesh_ResumeUpdates ).

Q3Mesh_GetComponentNumVertices

You can use the Q3Mesh_GetComponentNumVertices function to determine the number of vertices in a component of a mesh.

TQ3Status Q3Mesh_GetComponentNumVertices (
                     TQ3GeometryObject mesh,
                     TQ3MeshComponent component,
                     unsigned long *numVertices);
mesh
A mesh.
component
A mesh component.
numVertices
On exit, the number of vertices in the specified mesh component.

DESCRIPTION

The Q3Mesh_GetComponentNumVertices function returns, in the numVertices parameter, the number of vertices in the mesh component specified by the mesh and component parameters.

SPECIAL CONSIDERATIONS

The Q3Mesh_GetComponentNumVertices function might not accurately report the number of vertices in a mesh component if called while mesh updating is delayed (that is, after a call to Q3Mesh_DelayUpdates but before the matching call to Q3Mesh_ResumeUpdates ).

Q3Mesh_GetComponentNumEdges

You can use the Q3Mesh_GetComponentNumEdges function to determine the number of edges in a component of a mesh.

TQ3Status Q3Mesh_GetComponentNumEdges (
                     TQ3GeometryObject mesh,
                     TQ3MeshComponent component,
                     unsigned long *numEdges);
mesh
A mesh.
component
A mesh component.
numEdges
On exit, the number of edges in the specified mesh component.

DESCRIPTION

The Q3Mesh_GetComponentNumEdges function returns, in the numEdges parameter, the number of edges in the mesh component specified by the mesh and component parameters.

SPECIAL CONSIDERATIONS

The Q3Mesh_GetComponentNumEdges function might not accurately report the number of edges in a mesh component if called while mesh updating is delayed (that is, after a call to Q3Mesh_DelayUpdates but before the matching call to Q3Mesh_ResumeUpdates ).

Q3Mesh_GetComponentBoundingBox

You can use the Q3Mesh_GetComponentBoundingBox function to determine the bounding box of a component of a mesh.

TQ3Status Q3Mesh_GetComponentBoundingBox (
                     TQ3GeometryObject mesh,
                     TQ3MeshComponent component,
                     TQ3BoundingBox *boundingBox);
mesh
A mesh.
component
A mesh component.
boundingBox
On exit, the bounding box of the specified mesh component.

DESCRIPTION

The Q3Mesh_GetComponentBoundingBox function returns, in the boundingBox parameter, the bounding box of the mesh component specified by the mesh and component parameters.

SPECIAL CONSIDERATIONS

The Q3Mesh_GetComponentBoundingBox function might not accurately report the bounding box of a mesh component if called while mesh updating is delayed (that is, after a call to Q3Mesh_DelayUpdates but before the matching call to Q3Mesh_ResumeUpdates ).

Q3Mesh_GetComponentOrientable

You can use the Q3Mesh_GetComponentOrientable function to determine whether the faces of a component of a mesh can be consistently oriented.

TQ3Status Q3Mesh_GetComponentOrientable (
                     TQ3GeometryObject mesh,
                     TQ3MeshComponent component,
                     TQ3Boolean *orientable);
mesh
A mesh.
component
A mesh component.
orientable
On exit, a Boolean value that indicates whether the faces of the specified mesh component can be consistently oriented.

DESCRIPTION

The Q3Mesh_GetComponentOrientable function returns, in the orientable parameter, the value kQ3True if the faces of the mesh component specified by the mesh and component parameters can be consistently oriented; Q3Mesh_GetComponentOrientable returns kQ3False otherwise.

SPECIAL CONSIDERATIONS

The Q3Mesh_GetComponentOrientable function might not accurately report the orientation state of a mesh component if called while mesh updating is delayed (that is, after a call to Q3Mesh_DelayUpdates but before the matching call to Q3Mesh_ResumeUpdates ).

Q3Mesh_GetVertexCoordinates

You can use the Q3Mesh_GetVertexCoordinates function to get the coordinates of a vertex of a mesh.

TQ3Status Q3Mesh_GetVertexCoordinates (
                     TQ3GeometryObject mesh,
                     TQ3MeshVertex vertex,
                     TQ3Point3D *coordinates);
mesh
A mesh.
vertex
A mesh vertex.
coordinates
On exit, the coordinates of the specified mesh vertex.

DESCRIPTION

The Q3Mesh_GetVertexCoordinates function returns, in the coordinates parameter, the coordinates of the mesh vertex specified by the mesh and vertex parameters.

Q3Mesh_SetVertexCoordinates

You can use the Q3Mesh_SetVertexCoordinates function to set the coordinates of a vertex of a mesh.

TQ3Status Q3Mesh_SetVertexCoordinates (
                     TQ3GeometryObject mesh,
                     TQ3MeshVertex vertex,
                     const TQ3Point3D *coordinates);
mesh
A mesh.
vertex
A mesh vertex.
coordinates
The desired coordinates of the specified mesh vertex.

DESCRIPTION

The Q3Mesh_SetVertexCoordinates function sets the coordinates of the mesh vertex specified by the mesh and vertex parameters to those specified in the coordinates parameter.

Q3Mesh_GetVertexIndex

You can use the Q3Mesh_GetVertexIndex function to get the index of a mesh vertex.

TQ3Status Q3Mesh_GetVertexIndex (
                     TQ3GeometryObject mesh,
                     TQ3MeshVertex vertex,
                     unsigned long *index);
mesh
A mesh.
vertex
A mesh vertex.
index
On exit, the index of the specified mesh vertex.

DESCRIPTION

The Q3Mesh_GetVertexIndex function returns, in the index parameter, the index of the mesh vertex specified by the mesh and vertex parameters. A vertex index is a unique integer (between 0 and the total number of vertices in the mesh minus 1) associated with a vertex.

Vertex indices are volatile and can be changed by functions that alter the topology of a mesh (such as functions that add or delete faces or vertices), and by writing, picking, rendering, or duplicating a mesh, or by calling Q3Mesh_DelayUpdates . As a result, you should rely on an index returned by Q3Mesh_GetVertexIndex only until you perform one of these operations.

Q3Mesh_GetVertexOnBoundary

You can use the Q3Mesh_GetVertexOnBoundary function to determine whether a vertex lies on the boundary of a mesh.

TQ3Status Q3Mesh_GetVertexOnBoundary (
                     TQ3GeometryObject mesh,
                     TQ3MeshVertex vertex,
                     TQ3Boolean *onBoundary);
mesh
A mesh.
vertex
A mesh vertex.
onBoundary
On exit, a Boolean value that indicates whether the specified mesh vertex lies on the boundary of the mesh.

DESCRIPTION

The Q3Mesh_GetVertexOnBoundary function returns, in the onBoundary parameter, the value kQ3True if the mesh vertex specified by the mesh and vertex parameters lies on the boundary of the mesh. Q3Mesh_GetVertexOnBoundary returns kQ3False otherwise.

Q3Mesh_GetVertexComponent

You can use the Q3Mesh_GetVertexComponent function to get the component of a mesh to which a vertex belongs.

TQ3Status Q3Mesh_GetVertexComponent (
                     TQ3GeometryObject mesh,
                     TQ3MeshVertex vertex,
                     TQ3MeshComponent *component);
mesh
A mesh.
vertex
A mesh vertex.
component
On exit, the mesh component that contains the specified mesh vertex.

DESCRIPTION

The Q3Mesh_GetVertexComponent function returns, in the component parameter, the mesh component that contains the mesh vertex specified by the mesh and vertex parameters.

SPECIAL CONSIDERATIONS

The Q3Mesh_GetVertexComponent function might not accurately report the mesh component that contains a mesh vertex if called while mesh updating is delayed (that is, after a call to Q3Mesh_DelayUpdates but before the matching call to Q3Mesh_ResumeUpdates ).

Q3Mesh_GetVertexAttributeSet

You can use the Q3Mesh_GetVertexAttributeSet function to get the attribute set of a vertex of a mesh.

TQ3Status Q3Mesh_GetVertexAttributeSet (
                     TQ3GeometryObject mesh,
                     TQ3MeshVertex vertex,
                     TQ3AttributeSet *attributeSet);
mesh
A mesh.
vertex
A mesh vertex.
attributeSet
On exit, a pointer to the set of attributes for the mesh vertex.

DESCRIPTION

The Q3Mesh_GetVertexAttributeSet function returns, in the attributeSet parameter, the set of attributes currently associated with the mesh vertex specified by the mesh and vertex parameters. The reference count of the set is incremented.

Q3Mesh_SetVertexAttributeSet

You can use the Q3Mesh_SetVertexAttributeSet function to set the attribute set of a vertex of a mesh.

TQ3Status Q3Mesh_SetVertexAttributeSet (
                     TQ3GeometryObject mesh,
                     TQ3MeshVertex vertex,
                     TQ3AttributeSet attributeSet);
mesh
A mesh.
vertex
A mesh vertex.
attributeSet
The desired set of attributes for the specified mesh vertex.

DESCRIPTION

The Q3Mesh_SetVertexAttributeSet function sets the attribute set of the mesh vertex specified by the mesh and vertex parameters to the set of attributes specified by the attributeSet parameter.

Q3Mesh_GetFaceNumVertices

You can use the Q3Mesh_GetFaceNumVertices function to determine the number of vertices in a face of a mesh.

TQ3Status Q3Mesh_GetFaceNumVertices (
                     TQ3GeometryObject mesh,
                     TQ3MeshFace face,
                     unsigned long *numVertices);
mesh
A mesh.
face
A mesh face.
numVertices
On exit, the number of vertices in the specified mesh face.

DESCRIPTION

The Q3Mesh_GetFaceNumVertices function returns, in the numVertices parameter, the number of vertices in the mesh face specified by the mesh and face parameters.

Q3Mesh_GetFacePlaneEquation

You can use the Q3Mesh_GetFacePlaneEquation function to determine the plane equation of a face of a mesh.

TQ3Status Q3Mesh_GetFacePlaneEquation (
                     TQ3GeometryObject mesh,
                     TQ3MeshFace face,
                     TQ3PlaneEquation *planeEquation);
mesh
A mesh.
face
A mesh face.
planeEquation
On exit, the plane equation of the plane spanned by the vertices of the specified mesh face.

DESCRIPTION

The Q3Mesh_GetFacePlaneEquation function returns, in the planeEquation parameter, the plane equation of the plane spanned by the vertices of the mesh face specified by the mesh and face parameters. If the vertices of the mesh face do not all lie in one plane, the information returned in the planeEquation parameter is only an approximation.

Q3Mesh_GetFaceNumContours

You can use the Q3Mesh_GetFaceNumContours function to determine the number of contours in a face of a mesh.

TQ3Status Q3Mesh_GetFaceNumContours (
                     TQ3GeometryObject mesh,
                     TQ3MeshFace face,
                     unsigned long *numContours);
mesh
A mesh.
face
A mesh face.
numContours
On exit, the number of contours in the specified mesh face.

DESCRIPTION

The Q3Mesh_GetFaceNumContours function returns, in the numContours parameter, the number of contours in the mesh face specified by the mesh and face parameters. A mesh face always contains at least one contour, which defines the face itself. Any additional contours in the face define holes in the face.

Q3Mesh_GetFaceIndex

You can use the Q3Mesh_GetFaceIndex function to get the index of a mesh face.

TQ3Status Q3Mesh_GetFaceIndex (
                     TQ3GeometryObject mesh,
                     TQ3MeshFace face,
                     unsigned long *index);
mesh
A mesh.
face
A mesh face.
index
On exit, the index of the specified mesh face.

DESCRIPTION

The Q3Mesh_GetFaceIndex function returns, in the index parameter, the index of the mesh face specified by the mesh and face parameters. A face index is a unique integer (between 0 and the total number of faces in the mesh minus 1) associated with a face.

Face indices are volatile and can be changed by functions that alter the topology of a mesh (such as functions that add or delete faces or vertices), and by writing, picking, rendering, or duplicating a mesh, or by calling Q3Mesh_DelayUpdates . As a result, you should rely on an index returned by Q3Mesh_GetFaceIndex only until you perform one of these operations.

Q3Mesh_GetFaceComponent

You can use the Q3Mesh_GetFaceComponent function to get the component of a mesh to which a face belongs.

TQ3Status Q3Mesh_GetFaceComponent (
                     TQ3GeometryObject mesh,
                     TQ3MeshFace face,
                     TQ3MeshComponent *component);
mesh
A mesh.
face
A mesh face.
component
On exit, the mesh component that contains the specified mesh face.

DESCRIPTION

The Q3Mesh_GetFaceComponent function returns, in the component parameter, the mesh component that contains the mesh face specified by the mesh and face parameters.

SPECIAL CONSIDERATIONS

The Q3Mesh_GetFaceComponent function might not accurately report the mesh component that contains a mesh face if called while mesh updating is delayed (that is, after a call to Q3Mesh_DelayUpdates but before the matching call to Q3Mesh_ResumeUpdates ).

Q3Mesh_GetFaceAttributeSet

You can use the Q3Mesh_GetFaceAttributeSet function to get the attribute set of a face of a mesh.

TQ3Status Q3Mesh_GetFaceAttributeSet (
                     TQ3GeometryObject mesh,
                     TQ3MeshFace face,
                     TQ3AttributeSet *attributeSet);
mesh
A mesh.
face
A mesh face.
attributeSet
On exit, a pointer to the set of attributes for the specified mesh face.

DESCRIPTION

The Q3Mesh_GetFaceAttributeSet function returns, in the attributeSet parameter, the set of attributes currently associated with the mesh face specified by the mesh and face parameters. The reference count of the set is incremented.

Q3Mesh_SetFaceAttributeSet

You can use the Q3Mesh_SetFaceAttributeSet function to set the attribute set of a face of a mesh.

TQ3Status Q3Mesh_SetFaceAttributeSet (
                     TQ3GeometryObject mesh,
                     TQ3MeshFace face,
                     TQ3AttributeSet attributeSet);
mesh
A mesh.
face
A mesh face.
attributeSet
The desired set of attributes for the specified mesh face.

DESCRIPTION

The Q3Mesh_SetFaceAttributeSet function sets the attribute set of the mesh face specified by the mesh and face parameters to the set of attributes specified by the attributeSet parameter.

Q3Mesh_GetEdgeVertices

You can use the Q3Mesh_GetEdgeVertices function to get the vertices of a mesh edge.

TQ3Status Q3Mesh_GetEdgeVertices (
                     TQ3GeometryObject mesh,
                     TQ3MeshEdge edge,
                     TQ3MeshVertex *vertex1,
                     TQ3MeshVertex *vertex2);
mesh
A mesh.
edge
A mesh edge.
vertex1
On exit, the first vertex of the specified mesh edge.
vertex2
On exit, the second vertex of the specified mesh edge.

DESCRIPTION

The Q3Mesh_GetEdgeVertices function returns, in the vertex1 and vertex2 parameters, the two vertices of the mesh edge specified by the mesh and edge parameters.

Q3Mesh_GetEdgeFaces

You can use the Q3Mesh_GetEdgeFaces function to get the faces that share a mesh edge.

TQ3Status Q3Mesh_GetEdgeFaces (
                     TQ3GeometryObject mesh,
                     TQ3MeshEdge edge,
                     TQ3MeshFace *face1,
                     TQ3MeshFace *face2);
mesh
A mesh.
edge
A mesh edge.
face1
On exit, the first mesh face that shares the specified mesh edge.
face2
On exit, the second mesh face that shares the specified mesh edge.

DESCRIPTION

The Q3Mesh_GetEdgeFaces function returns, in the face1 and face2 parameters, the two mesh faces that shares the mesh edge specified by the mesh and edge parameters. If the edge lies on the boundary of the mesh, either face1 or face2 is NULL .

Q3Mesh_GetEdgeOnBoundary

You can use the Q3Mesh_GetEdgeOnBoundary function to determine whether a mesh edge lies on the boundary of the mesh.

TQ3Status Q3Mesh_GetEdgeOnBoundary (
                     TQ3GeometryObject mesh,
                     TQ3MeshEdge edge,
                     TQ3Boolean *onBoundary);
mesh
A mesh.
edge
A mesh edge.
onBoundary
On exit, a Boolean value that indicates whether the specified mesh edge lies on the boundary of the mesh.

DESCRIPTION

The Q3Mesh_GetEdgeOnBoundary function returns, in the onBoundary parameter, the value kQ3True if the mesh edge specified by the mesh and edge parameters lies on the boundary of the mesh. Q3Mesh_GetEdgeOnBoundary returns kQ3False otherwise.

Q3Mesh_GetEdgeComponent

You can use the Q3Mesh_GetEdgeComponent function to get the component of a mesh to which an edge belongs.

TQ3Status Q3Mesh_GetEdgeComponent (
                     TQ3GeometryObject mesh,
                     TQ3MeshEdge edge,
                     TQ3MeshComponent *component);
mesh
A mesh.
edge
A mesh edge.
component
On exit, the mesh component that contains the specified mesh edge.

DESCRIPTION

The Q3Mesh_GetEdgeComponent function returns, in the component parameter, the mesh component that contains the mesh edge specified by the mesh and edge parameters.

SPECIAL CONSIDERATIONS

The Q3Mesh_GetEdgeComponent function might not accurately report the mesh component that contains a mesh edge if called while mesh updating is delayed (that is, after a call to Q3Mesh_DelayUpdates but before the matching call to Q3Mesh_ResumeUpdates ).

Q3Mesh_GetEdgeAttributeSet

You can use the Q3Mesh_GetEdgeAttributeSet function to get the attribute set of an edge of a mesh.

TQ3Status Q3Mesh_GetEdgeAttributeSet (
                     TQ3GeometryObject mesh,
                     TQ3MeshEdge edge,
                     TQ3AttributeSet *attributeSet);
mesh
A mesh.
edge
A mesh edge.
attributeSet
On exit, a pointer to the set of attributes for the specified mesh edge.

DESCRIPTION

The Q3Mesh_GetEdgeAttributeSet function returns, in the attributeSet parameter, the set of attributes currently associated with the mesh edge specified by the mesh and edge parameters. The reference count of the set is incremented.

Q3Mesh_SetEdgeAttributeSet

You can use the Q3Mesh_SetEdgeAttributeSet function to set the attribute set of an edge of a mesh.

TQ3Status Q3Mesh_SetEdgeAttributeSet (
                     TQ3GeometryObject mesh,
                     TQ3MeshEdge edge,
                     TQ3AttributeSet attributeSet);
mesh
A mesh.
edge
A mesh edge.
attributeSet
The desired set of attributes for the specified mesh edge.

DESCRIPTION

The Q3Mesh_SetEdgeAttributeSet function sets the attribute set of the mesh edge specified by the mesh and edge parameters to the set of attributes specified by the attributeSet parameter.

Q3Mesh_GetContourFace

You can use the Q3Mesh_GetContourFace function to get the mesh face that contains a mesh contour.

TQ3Status Q3Mesh_GetContourFace (
                     TQ3GeometryObject mesh,
                     TQ3MeshContour contour,
                     TQ3MeshFace *face);
mesh
A mesh.
contour
A mesh contour.
face
On exit, the mesh face that contains the specified contour.

DESCRIPTION

The Q3Mesh_GetContourFace function returns, in the face parameter, the mesh face that contains the mesh contour specified by the mesh and contour parameters.

Q3Mesh_GetContourNumVertices

You can use the Q3Mesh_GetContourNumVertices function to get the number of vertices that define a contour.

TQ3Status Q3Mesh_GetContourNumVertices (
                     TQ3GeometryObject mesh,
                     TQ3MeshContour contour,
                     unsigned long *numVertices);
mesh
A mesh.
contour
A mesh contour.
numVertices
On exit, the number of vertices in the specified mesh contour.

DESCRIPTION

The Q3Mesh_GetContourNumVertices function returns, in the numVertices parameter, the number of vertices that compose the mesh contour specified by the mesh and contour parameters.

Q3Mesh_GetCornerAttributeSet

You can use the Q3Mesh_GetCornerAttributeSet function to get the attribute set of a mesh corner.

TQ3Status Q3Mesh_GetCornerAttributeSet (
                     TQ3GeometryObject mesh,
                     TQ3MeshVertex vertex,
                     TQ3MeshFace face,
                     TQ3AttributeSet *attributeSet);
mesh
A mesh.
vertex
A mesh vertex.
face
A mesh face. This face must contain the specified vertex in one of its contours.
attributeSet
On exit, the set of attributes for the corner defined by the specified mesh vertex and face.

DESCRIPTION

The Q3Mesh_GetCornerAttributeSet function returns, in the attributeSet parameter, the set of attributes of the corner defined by the vertex and face parameters in the mesh specified by the mesh parameter. The corner attributes override any attributes associated with the vertex alone. The reference count of the set is incremented.

Q3Mesh_SetCornerAttributeSet

You can use the Q3Mesh_SetCornerAttributeSet function to set the attribute set of a mesh corner.

TQ3Status Q3Mesh_SetCornerAttributeSet (
                     TQ3GeometryObject mesh,
                     TQ3MeshVertex vertex,
                     TQ3MeshFace face,
                     TQ3AttributeSet attributeSet);
mesh
A mesh.
vertex
A mesh vertex.
face
A mesh face. This face must contain the specified vertex in one of its contours.
attributeSet
The desired set of attributes for the corner defined by the specified mesh vertex and face.

DESCRIPTION

The Q3Mesh_SetCornerAttributeSet function sets the attribute set of the corner defined by the vertex and face parameters in the mesh specified by the mesh parameter to the set of attributes specified by the attributeSet parameter. The corner attributes override any attributes associated with the vertex alone.


© 1997 Apple Computer, Inc.

Previous | QD3D Book | Overview | Chapter Contents | Next |